<template>
  <div>
    <Header />
    <div class="bigbox">
      <div class="content" v-for="(v, i) in arr" :key="i">
        <img :src="v.url" class="img" />
        <div class="name">{{ v.name }}</div>
        <span>{{ v.price }}</span
        ><span
          >{{ v.text }}&nbsp;&nbsp;<img
            src="194.png"
            class="yu"
          />&nbsp;&nbsp;x</span
        ><span>{{ v.num }}</span>
      </div>
    </div>
    <!-- <Footernav /> -->
  <Footer class="footer"/>
  </div>
</template> 

<script>
import Header from './header.vue';
import Footer from './Footer.vue';
// import Footernav from "./footernav.vue";
import getlink from "../api/getapi.js";
export default {
  data() {
    return {
      arr: [],
    };
  },
  mounted() {
    getlink("/data/list").then((ok) => {
      this.arr = ok.data.yuan;
    });
  },
  components: {
    Footer,
    // Footernav,
        Header,
  },
};
</script>

<style scoped>
.footer{
  position: fixed;
  bottom: 0;
  left: 0;
}
.bigbox {
  width: 90%;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  margin-top: 0.2rem;
  flex-wrap: wrap;
}
.img {
  width: 1.65rem;
  height: 1.65rem;
}
.content {
  width: 47%;
  margin-bottom: 0.2rem;
}
.cu {
  font-weight: 900;
}
.yu {
  width: 0.1rem;
  height: 0.2rem;
  vertical-align: middle;
}
.name {
  margin: 0.1rem 0;
}
span {
  margin-right: 0.1rem;
  font-weight: 900;
}
</style>